import request from '@/utils/request'

// 查询优化建议信息列表
export function listRiskGoodsNameKeySuggest (query) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/list',
    method: 'get',
    params: query
  })
}

// count
export function count () {
  return request({
    url: '/system/riskGoodsNameKeySuggest/count',
    method: 'get'
  })
}

// 查询优化建议信息详细
export function getRiskGoodsNameKeySuggest (id) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/' + id,
    method: 'get'
  })
}

// 新增优化建议信息
export function addRiskGoodsNameKeySuggest (data) {
  return request({
    url: '/system/riskGoodsNameKeySuggest',
    method: 'post',
    data: data
  })
}

// 修改优化建议信息
export function updateRiskGoodsNameKeySuggest (data) {
  return request({
    url: '/system/riskGoodsNameKeySuggest',
    method: 'put',
    data: data
  })
}

// 删除优化建议信息
export function delRiskGoodsNameKeySuggest (id) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/' + id,
    method: 'delete'
  })
}

// 导出优化建议信息
export function exportRiskGoodsNameKeySuggest (query) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/export',
    method: 'get',
    params: query
  })
}

export function apply (data) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/apply',
    method: 'post',
    data
  })
}

export function confirm (data) {
  return request({
    url: '/system/riskGoodsNameKeySuggest/confirm',
    method: 'post',
    data
  })
}